
package com.jiuqi.ccp.generator.form;

import java.text.ParseException;
import java.text.SimpleDateFormat;

import javax.servlet.http.HttpServletRequest;

import org.apache.struts.action.ActionError;
import org.apache.struts.action.ActionErrors;
import org.apache.struts.action.ActionForm;
import org.apache.struts.action.ActionMapping;

/**
 * Form for ccpMscMonitor.
 *
 * @author <a href="http://boss.bekk.no/boss/middlegen/"/>Middlegen</a>
 *
 * @struts.form name="ccpMscMonitorForm"
 */
public class CcpMscMonitorForm extends ActionForm {

   private final static SimpleDateFormat FORMAT = new SimpleDateFormat("dd.MM.yyyy hh:mm:ss");

   private java.lang.String _cmmGuid = null;
   private java.lang.String _opTime = null;
   private java.lang.String _loginIp = null;
   private java.lang.String _userGuid = null;
   private java.lang.String _serviceId = null;
   private java.lang.String _opResult = null;
   private java.lang.String _xtraInfo = null;
   private java.lang.String _logType = null;
   private java.lang.String _businessDesc = null;
   private java.lang.String _reserved1 = null;
   private java.lang.String _reserved2 = null;
   private java.lang.String _reserved3 = null;

   /**
    * Standard constructor.
    */
   public CcpMscMonitorForm() {
   }

   /**
    * Returns the cmmGuid
    *
    * @return the cmmGuid
    */
   public java.lang.String getCmmGuid() {
      return _cmmGuid;
   }

   /**
    * Sets the cmmGuid
    *
    * @param cmmGuid the new cmmGuid value
    */
   public void setCmmGuid(java.lang.String cmmGuid) {
      _cmmGuid = cmmGuid;
   }
   /**
    * Returns the opTime
    *
    * @return the opTime
    */
   public java.lang.String getOpTime() {
      return _opTime;
   }

   /**
    * Sets the opTime
    *
    * @param opTime the new opTime value
    */
   public void setOpTime(java.lang.String opTime) {
      _opTime = opTime;
   }
   /**
    * Returns the loginIp
    *
    * @return the loginIp
    */
   public java.lang.String getLoginIp() {
      return _loginIp;
   }

   /**
    * Sets the loginIp
    *
    * @param loginIp the new loginIp value
    */
   public void setLoginIp(java.lang.String loginIp) {
      _loginIp = loginIp;
   }
   /**
    * Returns the userGuid
    *
    * @return the userGuid
    */
   public java.lang.String getUserGuid() {
      return _userGuid;
   }

   /**
    * Sets the userGuid
    *
    * @param userGuid the new userGuid value
    */
   public void setUserGuid(java.lang.String userGuid) {
      _userGuid = userGuid;
   }
   /**
    * Returns the serviceId
    *
    * @return the serviceId
    */
   public java.lang.String getServiceId() {
      return _serviceId;
   }

   /**
    * Sets the serviceId
    *
    * @param serviceId the new serviceId value
    */
   public void setServiceId(java.lang.String serviceId) {
      _serviceId = serviceId;
   }
   /**
    * Returns the opResult
    *
    * @return the opResult
    */
   public java.lang.String getOpResult() {
      return _opResult;
   }

   /**
    * Sets the opResult
    *
    * @param opResult the new opResult value
    */
   public void setOpResult(java.lang.String opResult) {
      _opResult = opResult;
   }
   /**
    * Returns the xtraInfo
    *
    * @return the xtraInfo
    */
   public java.lang.String getXtraInfo() {
      return _xtraInfo;
   }

   /**
    * Sets the xtraInfo
    *
    * @param xtraInfo the new xtraInfo value
    */
   public void setXtraInfo(java.lang.String xtraInfo) {
      _xtraInfo = xtraInfo;
   }
   /**
    * Returns the logType
    *
    * @return the logType
    */
   public java.lang.String getLogType() {
      return _logType;
   }

   /**
    * Sets the logType
    *
    * @param logType the new logType value
    */
   public void setLogType(java.lang.String logType) {
      _logType = logType;
   }
   /**
    * Returns the businessDesc
    *
    * @return the businessDesc
    */
   public java.lang.String getBusinessDesc() {
      return _businessDesc;
   }

   /**
    * Sets the businessDesc
    *
    * @param businessDesc the new businessDesc value
    */
   public void setBusinessDesc(java.lang.String businessDesc) {
      _businessDesc = businessDesc;
   }
   /**
    * Returns the reserved1
    *
    * @return the reserved1
    */
   public java.lang.String getReserved1() {
      return _reserved1;
   }

   /**
    * Sets the reserved1
    *
    * @param reserved1 the new reserved1 value
    */
   public void setReserved1(java.lang.String reserved1) {
      _reserved1 = reserved1;
   }
   /**
    * Returns the reserved2
    *
    * @return the reserved2
    */
   public java.lang.String getReserved2() {
      return _reserved2;
   }

   /**
    * Sets the reserved2
    *
    * @param reserved2 the new reserved2 value
    */
   public void setReserved2(java.lang.String reserved2) {
      _reserved2 = reserved2;
   }
   /**
    * Returns the reserved3
    *
    * @return the reserved3
    */
   public java.lang.String getReserved3() {
      return _reserved3;
   }

   /**
    * Sets the reserved3
    *
    * @param reserved3 the new reserved3 value
    */
   public void setReserved3(java.lang.String reserved3) {
      _reserved3 = reserved3;
   }


   /**
    * Validate the properties that have been set from this HTTP request,
    * and return an <code>ActionErrors</code> object that encapsulates any
    * validation errors that have been found.  If no errors are found, return
    * <code>null</code> or an <code>ActionErrors</code> object with no
    * recorded error messages.
    *
    * @param mapping The mapping used to select this instance
    * @param request The servlet request we are processing
    */
   public ActionErrors validate(ActionMapping mapping, HttpServletRequest request) {
      ActionErrors errors = new ActionErrors();
      // test for nullity
      if(getCmmGuid() == null) {
         errors.add("cmmGuid", new ActionError("error.cmmGuid.required"));
      }
      // TODO test format/data
      return errors;
   }
}
